package com.itshizhan.designpattern.abstract_factory.listfactory;

import com.itshizhan.designpattern.abstract_factory.factory.Link;

/**
 * 具体零件
 * 表示HTML链接的类
 */
public class ListLink extends Link {

    public ListLink(String caption, String url) {
        super(caption, url);
    }

    @Override
    public String makeHTML() {
        return "<li> <a href=\"" + url + "\">"  + caption + "</a> </li>\n";
    }
}
